#pragma once
#include<iostream>
#include <yaml-cpp/yaml.h>

bool LoadConfig(std::string const& file) {
  YAML::Node root;
  try {
    root = YAML::LoadFile(file);
    if (!root["test"].IsDefined()) {
      std::cout<<"error"<<std::endl;
      return false;
    }
    std::string domain = root["test"]["domain"].as<std::string>();
  }
  catch (YAML::Exception const& e) {
    return false;
  } catch (std::exception const& e) {
    return false;
}
}
